import Vue from 'vue'
import VueRouter from 'vue-router'
import HomeView from '../views/HomeView.vue'
import AboutView from '../views/AboutView.vue'
Vue.use(VueRouter)

const routes = [{
  path: '/',
  name: 'Home',
  component: HomeView
}, {
  path: '/about',
  name: 'About',
  component: AboutView
}]

const router = new VueRouter({
  routes,
  mode: 'history' // 历史模式
})

export default router
